package com.newcoder.huawei;

import java.util.*;

/**
 * 数字颠倒
 */
public class HJ11 {

    public static void main(String[] args){
        Scanner in = new Scanner(System.in);
        while (in.hasNext()) {
            String inputLine = in.nextLine();
            char[] charArray = inputLine.toCharArray();
            StringBuffer stringBuffer = new StringBuffer();
            for (int i = charArray.length-1; i >= 0; i--) {
                stringBuffer.append(charArray[i]);
            }
            System.out.println(stringBuffer.toString());
        }
    }
}
